package com.zhx.threadcoreknowledge.createthread.wrongways;

/**
 * @author ：zhanghaixuan
 * @date ：Created in 2019-09-17 09:03
 * 用途         ： TODO  匿名内部类方式实现线程
 */
public class InnerClassDemo {

    public static void main(String[] args) {
        new Thread(new Runnable() {
            @Override
            public void run() {
                System.out.println(Thread.currentThread().getName());
            }
        }).start();

        new Thread(){
            @Override
            public void run() {
                System.out.println(Thread.currentThread().getName());
            }
        }.start();
    }
}
